<?php
// +----------------------------------------------------------------------
// | Iecms [ Make the most exquisite CMS ]
// +----------------------------------------------------------------------
// | Copyright (c) 2009~2019 http://www.iemoo.com All rights reserved.
// +----------------------------------------------------------------------
// | Author: iemoo <i@iemoo.com>
// +----------------------------------------------------------------------
// | DateTime: 2019/11/19 11:08
// +----------------------------------------------------------------------
namespace app\admin\validate;

use think\Validate;

/**
 * 验证器
 * @package app\admin\validate
 */
class Module extends Validate
{
    protected $rule = [
		'title'			=> 'require|chsAlpha|unique:Module',
        'name'			=> 'require|alpha|unique:Module',
		'description'	=> 'max:250',
        'status'		=> 'require|in:0,1'
    ];

    protected $message = [
        'title.require'			=> '请输入模型名称',
		'title.chsAlpha'		=> '模型名称只能是汉字和字母',
        'title.unique'			=> '模型名称已存在',
		'name.require'			=> '请输入表名称',
		'name.chsAlpha'			=> '表名称只能是字母',
        'name.unique'			=> '表名称已存在',
		'description.max'		=> '描述过长',
        'status.require'		=> '请选择状态',
		'status.in'				=> '状态不正确'
    ];

}